package net.neptech.repository;

import net.neptech.model.workflow.InstanceRecord;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.Collection;
import java.util.List;

@Repository
public interface InstanceRecordRepo extends JpaRepository<InstanceRecord,String> {
    List<InstanceRecord> findByFlowId(String flowId);

    List<InstanceRecord> findByFlowIdIn(Collection<String> flowIds);

//    List<InstanceRecord> findByInstanceId(Collection<String> instanceIds);

    List<InstanceRecord> findByProcessInstanceId(String processInstanceId);

    List<InstanceRecord> findByProcessInstanceIdIn(Collection<String> processInstanceIds);
}
